powered by
Plot of a Bayesian network.
bnplot(dag, shape = "ellipse", main = NULL, sub = NULL)
A BN object, an object of class "bn".
A character string defining the shape of the nodes, "ellipse" (default value), "circle" or "rectangle".
The main title of the graph displayed on the top.
The subtitle of the graph displayed at the bottom.
The Bayesian network is visualised.
The function is called from the "bnlearn" package which invokes the "Rgraphviz" package from Bioconductor and you need to install it first.
pchc, pc.skel
# NOT RUN { # simulate a dataset with continuous data x <- matrix( rnorm(200 * 10, 1, 10), nrow = 200 ) a <- pchc(x) bnplot(a$dag) # }
Run the code above in your browser using DataLab